/*
 * MainWindow.h
 *
 *  Created on: Feb 1, 2009
 *      Author: tandaica0612
 */

#ifndef MAINWINDOW_H_
#define MAINWINDOW_H_
#include <iostream>
#include <exception>
#include <gtkmm.h>
#include <libglademm.h>
#include <libglademm/xml.h>
#include <string>
#include <sqlite3.h>
#include <list>
#include <sstream>

class MainWindow:public Gtk::Window {
public:
	Gtk::ScrolledWindow* scrolledwindow1;
	MainWindow(BaseObjectType* cobject, const Glib::RefPtr<
			Gnome::Glade::Xml>& glade_xml);
	class ModelColumns : public Gtk::TreeModel::ColumnRecord
	  {
	  public:

	    ModelColumns()
	    { add(m_col_id); add(m_col_name); add(m_col_number); add(m_col_percentage);}

	    Gtk::TreeModelColumn<unsigned int> m_col_id;
	    Gtk::TreeModelColumn<Glib::ustring> m_col_name;
	    Gtk::TreeModelColumn<short> m_col_number;
	    Gtk::TreeModelColumn<int> m_col_percentage;
	  };
	ModelColumns m_Columns;
	Glib::RefPtr<Gtk::ListStore> m_refTreeModel;
	Gtk::TreeView* m_TreeView;
	virtual ~MainWindow();
};

#endif /* MAINWINDOW_H_ */
